#include <iostream>

int main() {
    int a,n,sum;
    scanf("%d %d", &a, &n);
    sum = a;
    while (n <= 0){
        scanf("%d", &n);
    }
    for (int i = 0; i<n-1; ++i) {
        sum += sum+1;
    }
    printf("%d",sum);
    return 0;
}
